<?php
class Clogin extends CI_Controller{
	public function __construct(){
		parent::__construct();
	}
	public function index(){
		$this->load->helper('form');
		$this->load->view('login');
	}
	public function checkLogin(){
		$userName = $_POST['username'];
		$passWord = $_POST['password'];
		$this->load->model('Muser');
		$checkLogin = $this->Muser->checkLogin($userName,$passWord);
		if($checkLogin){
			echo 1;
		}else {
			echo 0;
		}
	}
}